3.1.62 \(\int \frac {(a+a \sec (e+f x))^{5/2}}{(c-c \sec (e+f x))^3} \, dx\) [62]

Optimal. Leaf size=104 \[ \frac {2 a^{5/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^3 f}+\frac {2 a^2 \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^3 f}+\frac {8 \cot ^5(e+f x) (a+a \sec (e+f x))^{5/2}}{5 c^3 f} \]

[Out]

2*a^(5/2)*arctan(a^(1/2)*tan(f*x+e)/(a+a*sec(f*x+e))^(1/2))/c^3/f+8/5*cot(f*x+e)^5*(a+a*sec(f*x+e))^(5/2)/c^3/
f+2*a^2*cot(f*x+e)*(a+a*sec(f*x+e))^(1/2)/c^3/f

________________________________________________________________________________________

Rubi [A]
time = 0.12, antiderivative size = 104, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3989, 3972, 472, 209} \begin {gather*} \frac {2 a^{5/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{c^3 f}+\frac {2 a^2 \cot (e+f x) \sqrt {a \sec (e+f x)+a}}{c^3 f}+\frac {8 \cot ^5(e+f x) (a \sec (e+f x)+a)^{5/2}}{5 c^3 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + a*Sec[e + f*x])^(5/2)/(c - c*Sec[e + f*x])^3,x]

[Out]

(2*a^(5/2)*ArcTan[(Sqrt[a]*Tan[e + f*x])/Sqrt[a + a*Sec[e + f*x]]])/(c^3*f) + (2*a^2*Cot[e + f*x]*Sqrt[a + a*S
ec[e + f*x]])/(c^3*f) + (8*Cot[e + f*x]^5*(a + a*Sec[e + f*x])^(5/2))/(5*c^3*f)

Rule 209

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*ArcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 472

Int[(((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_))/((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Int[ExpandIntegr
and[(e*x)^m*((a + b*x^n)^p/(c + d*x^n)), x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b*c - a*d, 0] && IGtQ[n
, 0] && IGtQ[p, 0] && (IntegerQ[m] || IGtQ[2*(m + 1), 0] ||  !RationalQ[m])

Rule 3972

Int[cot[(c_.) + (d_.)*(x_)]^(m_.)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n_.), x_Symbol] :> Dist[-2*(a^(m/2 +
 n + 1/2)/d), Subst[Int[x^m*((2 + a*x^2)^(m/2 + n - 1/2)/(1 + a*x^2)), x], x, Cot[c + d*x]/Sqrt[a + b*Csc[c +
d*x]]], x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0] && IntegerQ[m/2] && IntegerQ[n - 1/2]

Rule 3989

Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.)*(csc[(e_.) + (f_.)*(x_)]*(d_.) + (c_))^(n_.), x_Symbol] :> Di
st[((-a)*c)^m, Int[Cot[e + f*x]^(2*m)*(c + d*Csc[e + f*x])^(n - m), x], x] /; FreeQ[{a, b, c, d, e, f, n}, x]
&& EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && IntegerQ[m] && RationalQ[n] &&  !(IntegerQ[n] && GtQ[m - n, 0])

Rubi steps

\begin {align*} \int \frac {(a+a \sec (e+f x))^{5/2}}{(c-c \sec (e+f x))^3} \, dx &=-\frac {\int \cot ^6(e+f x) (a+a \sec (e+f x))^{11/2} \, dx}{a^3 c^3}\\ &=\frac {2 \text {Subst}\left (\int \frac {\left (2+a x^2\right )^2}{x^6 \left (1+a x^2\right )} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^3 f}\\ &=\frac {2 \text {Subst}\left (\int \left (\frac {4}{x^6}+\frac {a^2}{x^2}-\frac {a^3}{1+a x^2}\right ) \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^3 f}\\ &=\frac {2 a^2 \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^3 f}+\frac {8 \cot ^5(e+f x) (a+a \sec (e+f x))^{5/2}}{5 c^3 f}-\frac {\left (2 a^3\right ) \text {Subst}\left (\int \frac {1}{1+a x^2} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^3 f}\\ &=\frac {2 a^{5/2} \tan ^{-1}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^3 f}+\frac {2 a^2 \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^3 f}+\frac {8 \cot ^5(e+f x) (a+a \sec (e+f x))^{5/2}}{5 c^3 f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [C] Result contains higher order function than in optimal. Order 5 vs. order 3 in optimal.
time = 5.47, size = 196, normalized size = 1.88 \begin {gather*} \frac {a^2 \sqrt {\cos (e+f x)} \sqrt {a (1+\sec (e+f x))} \left (30 \text {ArcSin}\left (\sqrt {1-\cos (e+f x)}\right ) \cos ^2\left (\frac {1}{2} (e+f x)\right ) \sqrt {1-\cos (e+f x)} (-1+7 \cos (e+f x))+4 (-29+20 \cos (e+f x)-15 \cos (2 (e+f x))) \, _2F_1\left (-\frac {5}{2},-\frac {1}{2};\frac {1}{2};2 \sin ^2\left (\frac {1}{2} (e+f x)\right )\right )+5 \sqrt {\cos (e+f x)} (11 \cos (e+f x)+3 \cos (2 (e+f x))) \sin ^2(e+f x)\right ) \tan \left (\frac {1}{2} (e+f x)\right )}{60 c^3 f (-1+\cos (e+f x))^3} \end {gather*}

Warning: Unable to verify antiderivative.

[In]

Integrate[(a + a*Sec[e + f*x])^(5/2)/(c - c*Sec[e + f*x])^3,x]

[Out]

(a^2*Sqrt[Cos[e + f*x]]*Sqrt[a*(1 + Sec[e + f*x])]*(30*ArcSin[Sqrt[1 - Cos[e + f*x]]]*Cos[(e + f*x)/2]^2*Sqrt[
1 - Cos[e + f*x]]*(-1 + 7*Cos[e + f*x]) + 4*(-29 + 20*Cos[e + f*x] - 15*Cos[2*(e + f*x)])*Hypergeometric2F1[-5
/2, -1/2, 1/2, 2*Sin[(e + f*x)/2]^2] + 5*Sqrt[Cos[e + f*x]]*(11*Cos[e + f*x] + 3*Cos[2*(e + f*x)])*Sin[e + f*x
]^2)*Tan[(e + f*x)/2])/(60*c^3*f*(-1 + Cos[e + f*x])^3)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(305\) vs. \(2(92)=184\).
time = 0.24, size = 306, normalized size = 2.94

method result size
default \(\frac {\sqrt {\frac {a \left (\cos \left (f x +e \right )+1\right )}{\cos \left (f x +e \right )}}\, \left (-5 \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \left (\cos ^{2}\left (f x +e \right )\right ) \sin \left (f x +e \right ) \sqrt {2}+10 \sin \left (f x +e \right ) \cos \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}-5 \sqrt {2}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right )+18 \left (\cos ^{3}\left (f x +e \right )\right )-20 \left (\cos ^{2}\left (f x +e \right )\right )+10 \cos \left (f x +e \right )\right ) a^{2}}{5 c^{3} f \sin \left (f x +e \right ) \left (-1+\cos \left (f x +e \right )\right )^{2}}\) \(306\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^3,x,method=_RETURNVERBOSE)

[Out]

1/5/c^3/f*(a*(cos(f*x+e)+1)/cos(f*x+e))^(1/2)*(-5*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(1/2*(-2*cos(f*x
+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)/cos(f*x+e)*2^(1/2))*cos(f*x+e)^2*sin(f*x+e)*2^(1/2)+10*sin(f*x+e)*cos(f*x
+e)*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)/cos(f*x+e
)*2^(1/2))*2^(1/2)-5*2^(1/2)*arctanh(1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)/cos(f*x+e)*2^(1/2))*(
-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)+18*cos(f*x+e)^3-20*cos(f*x+e)^2+10*cos(f*x+e))/sin(f*x+e)/(-1+c
os(f*x+e))^2*a^2

________________________________________________________________________________________

Maxima [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^3,x, algorithm="maxima")

[Out]

Timed out

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 224 vs. \(2 (98) = 196\).
time = 3.51, size = 477, normalized size = 4.59 \begin {gather*} \left [\frac {5 \, {\left (a^{2} \cos \left (f x + e\right )^{2} - 2 \, a^{2} \cos \left (f x + e\right ) + a^{2}\right )} \sqrt {-a} \log \left (-\frac {8 \, a \cos \left (f x + e\right )^{3} - 4 \, {\left (2 \, \cos \left (f x + e\right )^{2} - \cos \left (f x + e\right )\right )} \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right ) - 7 \, a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right ) + 1}\right ) \sin \left (f x + e\right ) + 4 \, {\left (9 \, a^{2} \cos \left (f x + e\right )^{3} - 10 \, a^{2} \cos \left (f x + e\right )^{2} + 5 \, a^{2} \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}}}{10 \, {\left (c^{3} f \cos \left (f x + e\right )^{2} - 2 \, c^{3} f \cos \left (f x + e\right ) + c^{3} f\right )} \sin \left (f x + e\right )}, \frac {5 \, {\left (a^{2} \cos \left (f x + e\right )^{2} - 2 \, a^{2} \cos \left (f x + e\right ) + a^{2}\right )} \sqrt {a} \arctan \left (\frac {2 \, \sqrt {a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right )}{2 \, a \cos \left (f x + e\right )^{2} + a \cos \left (f x + e\right ) - a}\right ) \sin \left (f x + e\right ) + 2 \, {\left (9 \, a^{2} \cos \left (f x + e\right )^{3} - 10 \, a^{2} \cos \left (f x + e\right )^{2} + 5 \, a^{2} \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}}}{5 \, {\left (c^{3} f \cos \left (f x + e\right )^{2} - 2 \, c^{3} f \cos \left (f x + e\right ) + c^{3} f\right )} \sin \left (f x + e\right )}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^3,x, algorithm="fricas")

[Out]

[1/10*(5*(a^2*cos(f*x + e)^2 - 2*a^2*cos(f*x + e) + a^2)*sqrt(-a)*log(-(8*a*cos(f*x + e)^3 - 4*(2*cos(f*x + e)
^2 - cos(f*x + e))*sqrt(-a)*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*sin(f*x + e) - 7*a*cos(f*x + e) + a)/(cos(
f*x + e) + 1))*sin(f*x + e) + 4*(9*a^2*cos(f*x + e)^3 - 10*a^2*cos(f*x + e)^2 + 5*a^2*cos(f*x + e))*sqrt((a*co
s(f*x + e) + a)/cos(f*x + e)))/((c^3*f*cos(f*x + e)^2 - 2*c^3*f*cos(f*x + e) + c^3*f)*sin(f*x + e)), 1/5*(5*(a
^2*cos(f*x + e)^2 - 2*a^2*cos(f*x + e) + a^2)*sqrt(a)*arctan(2*sqrt(a)*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))
*cos(f*x + e)*sin(f*x + e)/(2*a*cos(f*x + e)^2 + a*cos(f*x + e) - a))*sin(f*x + e) + 2*(9*a^2*cos(f*x + e)^3 -
 10*a^2*cos(f*x + e)^2 + 5*a^2*cos(f*x + e))*sqrt((a*cos(f*x + e) + a)/cos(f*x + e)))/((c^3*f*cos(f*x + e)^2 -
 2*c^3*f*cos(f*x + e) + c^3*f)*sin(f*x + e))]

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \frac {\int \frac {a^{2} \sqrt {a \sec {\left (e + f x \right )} + a}}{\sec ^{3}{\left (e + f x \right )} - 3 \sec ^{2}{\left (e + f x \right )} + 3 \sec {\left (e + f x \right )} - 1}\, dx + \int \frac {2 a^{2} \sqrt {a \sec {\left (e + f x \right )} + a} \sec {\left (e + f x \right )}}{\sec ^{3}{\left (e + f x \right )} - 3 \sec ^{2}{\left (e + f x \right )} + 3 \sec {\left (e + f x \right )} - 1}\, dx + \int \frac {a^{2} \sqrt {a \sec {\left (e + f x \right )} + a} \sec ^{2}{\left (e + f x \right )}}{\sec ^{3}{\left (e + f x \right )} - 3 \sec ^{2}{\left (e + f x \right )} + 3 \sec {\left (e + f x \right )} - 1}\, dx}{c^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))**(5/2)/(c-c*sec(f*x+e))**3,x)

[Out]

-(Integral(a**2*sqrt(a*sec(e + f*x) + a)/(sec(e + f*x)**3 - 3*sec(e + f*x)**2 + 3*sec(e + f*x) - 1), x) + Inte
gral(2*a**2*sqrt(a*sec(e + f*x) + a)*sec(e + f*x)/(sec(e + f*x)**3 - 3*sec(e + f*x)**2 + 3*sec(e + f*x) - 1),
x) + Integral(a**2*sqrt(a*sec(e + f*x) + a)*sec(e + f*x)**2/(sec(e + f*x)**3 - 3*sec(e + f*x)**2 + 3*sec(e + f
*x) - 1), x))/c**3

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 428 vs. \(2 (92) = 184\).
time = 1.41, size = 428, normalized size = 4.12 \begin {gather*} -\frac {\frac {5 \, \sqrt {-a} a^{3} \log \left (\frac {{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}{{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} + 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right )}{c^{3} {\left | a \right |}} + \frac {4 \, \sqrt {2} {\left (5 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{8} \sqrt {-a} a^{3} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) - 10 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{6} \sqrt {-a} a^{4} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) + 20 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{4} \sqrt {-a} a^{5} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) - 10 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} \sqrt {-a} a^{6} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) + 3 \, \sqrt {-a} a^{7} \mathrm {sgn}\left (\cos \left (f x + e\right )\right )\right )}}{{\left ({\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - a\right )}^{5} c^{3}}}{5 \, f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^3,x, algorithm="giac")

[Out]

-1/5*(5*sqrt(-a)*a^3*log(abs(2*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2 + a))^2 - 4*sqr
t(2)*abs(a) - 6*a)/abs(2*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2 + a))^2 + 4*sqrt(2)*a
bs(a) - 6*a))*sgn(cos(f*x + e))/(c^3*abs(a)) + 4*sqrt(2)*(5*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f
*x + 1/2*e)^2 + a))^8*sqrt(-a)*a^3*sgn(cos(f*x + e)) - 10*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x
 + 1/2*e)^2 + a))^6*sqrt(-a)*a^4*sgn(cos(f*x + e)) + 20*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x +
 1/2*e)^2 + a))^4*sqrt(-a)*a^5*sgn(cos(f*x + e)) - 10*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1
/2*e)^2 + a))^2*sqrt(-a)*a^6*sgn(cos(f*x + e)) + 3*sqrt(-a)*a^7*sgn(cos(f*x + e)))/(((sqrt(-a)*tan(1/2*f*x + 1
/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2 + a))^2 - a)^5*c^3))/f

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^{5/2}}{{\left (c-\frac {c}{\cos \left (e+f\,x\right )}\right )}^3} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a/cos(e + f*x))^(5/2)/(c - c/cos(e + f*x))^3,x)

[Out]

int((a + a/cos(e + f*x))^(5/2)/(c - c/cos(e + f*x))^3, x)

________________________________________________________________________________________